<%@ page contentType="text/html; charset=UTF-8" %>
<%@ page pageEncoding="UTF-8" %>
<%@ taglib uri="/struts-tags" prefix="s" %>
<script type="text/javascript" language="JavaScript">
    $(document).ready(function() {
        $("#add-hotel-mapping").validate();
    });
</script>
<h1>Hotel</h1>

<div class="main">
    <div class="box_side search_hotel clearfix">
        <s:form action="" method="GET">
            <ul>
                <li><label>Derby Hotel Code：</label>
                    <s:textfield name="hotelMapping.derbyCode" cssClass="text"/>
                </li>
                <li><label>IHG Hotel Code：</label>
                    <s:textfield name="hotelMapping.cooperatorCode" cssClass="text"/>
                </li>
                <li><label>IHG Hotel Name：</label>
                    <s:textfield name="hotelMapping.hotelName" cssClass="text"/>
                </li>
                <li><label>Status：</label>
                    <s:select name="hotelMapping.status" list="hotelMapping.status"/>
                </li>
            </ul>
            <input type="submit" value="Search" class="common_button"/>
        </s:form>
    </div>
</div>
<div class="main">
    <jsp:include page="../../common/pagination.jsp"/>
    <table id="channel" class="table_list" cellpadding="0" cellspacing="0">
        <thead>
        <tr>
            <th>Derby Hotel Code</th>
            <th>IHG Hotel Code</th>
            <th>IHG Hotel Name</th>
            <th>Status</th>
            <th>Create Date</th>
        </tr>
        </thead>
        <tbody>
        <s:iterator value="paginater.objects">
            <tr>
                <td>${derbyCode}</td>
                <td>${cooperatorCode}</td>
                <td>${hotelName}</td>
                <td>${status}</td>
                <td><s:date name="createTime" format="yyyy-MM-dd HH:mm"/></td>
            </tr>
        </s:iterator>
        </tbody>
    </table>
</div>
<s:form id="add-hotel-mapping" action="save.dhtml" method="post">
    <div class="main">
        <jsp:include page="../../common/messages.jsp"/>
        <h1>Add Hotel Mapping</h1>
        <ul>
            <li style="margin-left:50px;">
                <label>Derby Hotel Code：</label><s:textfield name="hotelMapping.derbyCode" cssClass="required"/>
                &nbsp;&nbsp;&nbsp;&nbsp;
                <label>IHG Hotel Code：</label><s:textfield name="hotelMapping.cooperatorCode" cssClass="required"/>
                <input value="Add" class="common_button" type="submit">
                &nbsp;&nbsp;&nbsp;&nbsp;
                <label>IHG Hotel Name：</label><s:textfield name="hotelMapping.cooperatorCode" cssClass="required"/>
                <input value="Add" class="common_button" type="submit">
                &nbsp;&nbsp;&nbsp;&nbsp;
                <label>Status：</label><s:textfield name="hotelMapping.cooperatorCode" cssClass="required"/>
                <input value="Add" class="common_button" type="submit">
            </li>
        </ul>
    </div>
</s:form>
